]> dgit.raspbian.org Git - gnome-shell.git/commitdiff
overview: Really fix zoom animation
authorAdel Gadllah <adel.gadllah@gmail.com>
Wed, 26 Jun 2013 09:12:35 +0000 (11:12 +0200)
committerAdel Gadllah <adel.gadllah@gmail.com>
Wed, 26 Jun 2013 16:06:54 +0000 (18:06 +0200)
Commit 16fa186b633d attempted to fix the zoom animation problem
by throwing changes on the floor while the overview is animating. This has
the side effect that we might end up missing some positioning changes causes
windows to overlap the workspace thumbnails.

So revert those changes and fix it by simply by passing
WindowPositionFlags.ANIMATE during the overview animation.
This way the animation works as expected and we don't miss any position changes.

https://bugzilla.gnome.org/show_bug.cgi?id=703105

js/ui/workspace.js
js/ui/workspacesView.js

index 713750423eafa8ca457e61bbb38dbd5d859747f1..dc7e43e7d7b55b1db60e3aa62da14c1f444ff2aa 100644 (file)
@@ -997,7 +997,7 @@ const Workspace = new Lang.Class({
 
             this._dropRect.set_position(geom.x, geom.y);
             this._dropRect.set_size(geom.width, geom.height);
-            this._updateWindowPositions(WindowPositionFlags.NONE);
+            this._updateWindowPositions(Main.overview.animationInProgress ? WindowPositionFlags.ANIMATE : WindowPositionFlags.NONE);
 
             this._actualGeometryLater = 0;
             return false;
index 3eb9c0dcb363019292627304ef4a34cc8b270114..50f079c3e74c32280db538c5a15b07f9477e453b 100644 (file)
@@ -446,7 +446,7 @@ const WorkspacesDisplay = new Lang.Class({
 
     _init: function() {
         this.actor = new St.Widget({ clip_to_allocation: true });
-        this.actor.connect('notify::allocation', Lang.bind(this, this._allocationChanged));
+        this.actor.connect('notify::allocation', Lang.bind(this, this._updateWorkspacesActualGeometry));
         this.actor.connect('parent-set', Lang.bind(this, this._parentSet));
 
         let clickAction = new Clutter.ClickAction()
@@ -676,12 +676,6 @@ const WorkspacesDisplay = new Lang.Class({
         }
     },
 
-    _allocationChanged: function() {
-        if (Main.overview.animationInProgress)
-            return;
-        this._updateWorkspacesActualGeometry();
-    },
-
     _updateWorkspacesActualGeometry: function() {
         if (!this._workspacesViews.length)
             return;